# -*- coding: utf-8 -*-
# Author: xiantingDeng
# File: 04_不定长参数.py
# Time: 21:15


def sum_2_nums(a,b,*args,**kwargs):
    # 加上*号的变量代表可接受多个变量值
    print("-"*20)
    print(a)
    print(b)
    print(args)
    print(kwargs)


if __name__ == '__main__':
    # s = {"好家伙": "测试"}
    # print({"ceshi","sadjsk"})
    # print(sum_2_nums(1,2,3,4,5,6,demo="测试",done=89)) # 传入字典不长参数需要带变量名传入
    A = (44,55,66)
    B = {"age":18,"name":"laowang"}
    print(sum_2_nums(11,22,33,*A,**B)) # 不定长传参，使用* 传入
    # 相当于拆包


    print(id(A)) # 获取变量的地址